package com.example.demo.service;

import com.example.demo.dao.TBizAuctionArtDAO;
import com.example.demo.po.TBizAuctionArt;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;

@Service
public class TBizAuctionArtService {
    @Autowired
    TBizAuctionArtDAO tBizAuctionArtDAO;

    @Transactional
    public boolean save(TBizAuctionArt aa){
        int i = tBizAuctionArtDAO.save(aa);
        if(i>0)
            return true;
        else
            return false;
    }

    @Transactional
    public boolean update(TBizAuctionArt aa){
        int i = tBizAuctionArtDAO.update(aa);
        if(i>0)
            return true;
        else
            return false;
    }

    public TBizAuctionArt findByAA(TBizAuctionArt aa){
        return  tBizAuctionArtDAO.findByAA(aa);
    }

    public boolean del(TBizAuctionArt aa){
        int i = tBizAuctionArtDAO.del(aa);
        if(i>0)
            return true;
        else
            return false;
    }

}
